Skip to content

Clarify roles of patternProperties/patternKeys vs propertyNames/keyNames#4

Merged
clemensv merged 1 commit into
mainfrom
editorial/clarify-patternProperties-propertyNames
Jun 8, 2026
Merged

Clarify roles of patternProperties/patternKeys vs propertyNames/keyNames#4
clemensv merged 1 commit into
mainfrom
editorial/clarify-patternProperties-propertyNames

Conversation

@clemensv
Copy link
Copy Markdown
Contributor

@clemensv clemensv commented Jun 8, 2026

Addresses the ambiguity noted in #1:

  • patternProperties/patternKeys: clarified that these validate property values based on name patterns, and explicitly state they do NOT define or declare properties (they are validation-only constraints).
  • propertyNames/keyNames: clarified that these validate property names themselves, and explicitly contrast with patternProperties so readers understand when to use which.

Fixes #1

- patternProperties validates property VALUES based on name patterns;
  explicitly note it does not define or declare properties
- propertyNames validates property NAMES themselves against a schema
- Distinguish the two clearly so readers understand when to use which

Fixes #1

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@clemensv clemensv merged commit 6038cfd into main Jun 8, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clarify the role of "patternProperties and patternKeys"

1 participant